import Vue from 'vue'
import Router from 'vue-router'

// 一级路由
import Home from './../pages/home/home'
import Login from './../pages/loginMember/loginMember'
import AnswerSheet from './../pages/answerSheet/answerSheet'
import Rank from './../pages/rank/rank'

//二级路由


Vue.use(Router)

export default new Router({
  routes: [
    {
      path:'/login',
      component: Login,
      name: 'Login'
    },
    {
      path: '/',
      redirect:'/answerSheet'
    },
    {
      path:'/home',
      component: Home,
      name: 'Home',
      children:[
        {
          path: '/answerSheet',
          component: AnswerSheet,
          name: 'AnswerSheet',
        },
        {
          path: '/rank',
          component: Rank,
          name: 'Rank',
        },
      ],
    }
  ]
})
